package com.mybatis.config;

/**
 * mapper对象里的函数信息
 */
public class MapperFunctionInfo {

    private String name;
    private String sqlType; // update insert ...
    private String sql;
    private Class<?> resultType; // 接收sql执行结果的pojo对象的类型 Class<?>

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getSqlType() {
        return sqlType;
    }

    public void setSqlType(String sqlType) {
        this.sqlType = sqlType;
    }

    public String getSql() {
        return sql;
    }

    public void setSql(String sql) {
        this.sql = sql;
    }

    public Class<?> getResultType() {
        return resultType;
    }

    public void setResultType(Class<?> resultType) {
        this.resultType = resultType;
    }

    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder("mapper对象里的函数信息{");
        sb.append("name='").append(name).append('\'');
        sb.append(", sqlType='").append(sqlType).append('\'');
        sb.append(", sql='").append(sql).append('\'');
        sb.append(", resultType=").append(resultType);
        sb.append('}');
        return sb.toString();
    }
}
